

<%@ page import="desmontec.documentos.GuiaDeTrafego" %>
<html>
    <head>
        <meta name="layout" content="main" />
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        
    	<g:javascript library="jquery" />
    	<g:javascript library="prototype"/>
    	<g:javascript library="GuiaDeTrafego"/>
    	
        <g:set var="entityName" value="${message(code: 'guiaDeTrafego.label', default: 'GuiaDeTrafego')}" />
        <title><g:message code="Cadastrar Mapa de Estocagem" /></title>
    </head>
    <body>
        <div class="nav">
            
        </div>
        <div class="container">
        
        
        	<!-- CABECALHO -->
        	<div class="header">
				<h1><g:message code="Editar Guia de Tr&aacute;fego" /></h1>        	
			</div>
        
            
            <!-- MENU -->
			<div class="left">
				<g:include  view="_menu.gsp"></g:include>
			</div>
			
			 <!-- CORPO -->            
            <div class="content">
			<g:if test="${flash.message}">
            <div class="message">${flash.message}</div>
            </g:if>
            <g:hasErrors bean="${guiaDeTrafegoInstance}">
            <div class="errors">
                <g:renderErrors bean="${guiaDeTrafegoInstance}" as="list" />
            </div>
            </g:hasErrors>
            <g:form action="salvarEditarGuiaId" id="criarGuiaIdForm" name="criarGuiaIdForm" >
            	<g:hiddenField name="idGuia" id="idGuia" value="${guiaDeTrafegoInstance.id}"/>
                <div class="dialog">
                   <table cellpadding="2" cellspacing="0"  class="tabelaAzul">
                    	<thead>
							<tr>
								<th class="cabecalhoTabela"><g:message code= "Dados da Guia" /></th>
								<th class="cabecalhoTabela"></th>
							</tr>
						</thead>
                        <tbody>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="numeroDaGuia"><g:message code="GuiaDeTrafego.numeroDaGuia.label" default="Numero Da Guia" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'numeroDaGuia', 'errors')}">
                                    <g:textField name="numeroDaGuia" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'numeroDaGuia')}" />
                                </td>
                            </tr>
                        
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="dinamite"><g:message code="GuiaDeTrafego.dinamite.label" default="Dinamite" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'dinamite', 'errors')}">
                                    <g:textField name="dinamite" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'dinamite')}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="espoleta"><g:message code="GuiaDeTrafego.espoleta.label" default="Espoleta" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'espoleta', 'errors')}">
                                    <g:textField name="espoleta" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'espoleta')}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="estopim"><g:message code="GuiaDeTrafego.estopim.label" default="Estopim" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'estopim', 'errors')}">
                                    <g:textField name="estopim" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'estopim')}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="cordelDet"><g:message code="GuiaDeTrafego.cordelDet.label" default="Cordel Det" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'cordelDet', 'errors')}">
                                    <g:textField name="cordelDet" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'cordelDet')}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="espoletim"><g:message code="GuiaDeTrafego.espoletim.label" default="Espoletim" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'espoletim', 'errors')}">
                                    <g:textField name="espoletim" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'espoletim')}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="retardo"><g:message code="GuiaDeTrafego.retardo.label" default="Retardo" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: guiaDeTrafegoInstance, field: 'retardo', 'errors')}">
                                    <g:textField name="retardo" value="${fieldValue(bean: guiaDeTrafegoInstance, field: 'retardo')}" />
                                </td>
                            </tr>
                        
                        </tbody>
                    </table>
                </div>
               	<br />
            	<hr />  
            	<div class="buttons" align="right">
                   	<g:submitToRemote
                    		action='validarGuiaId'
                    		onFailure="erroResposta()"
                    		onSuccess="validarRespostaId(e)"
                    		value="Editar"
                    		class="edit" />
				</div>
            </g:form>
			</div>
			
			 <!-- RODAPE -->
            <div class="footer">
	            <span class="menuButton"><a class="home" href="${createLink(uri: '/')}"><g:message code="default.home.label"/></a></span>
            	<span class="menuButton"><g:link class="list" action="list"><g:message code="Mapas de Estocagem cadastrados" /></g:link></span>
            </div>
            
            
        </div>
    </body>
</html>
